package com.erp.bus.comm;



//封装 响应数据
public class ResultCode {

    public static final ResultCode SUCCESS_LOGIN = new ResultCode(Code.SUCCESS,"登录成功");
    public static final ResultCode FAIL_LOGIN = new ResultCode(Code.FAIL,"登录失败");

    public static final ResultCode SUCCESS_ADD = new ResultCode(Code.SUCCESS,"添加成功");
    public static final ResultCode FAIL_ADD = new ResultCode(Code.FAIL,"添加失败");

    public static final ResultCode SUCCESS_UPDATE = new ResultCode(Code.SUCCESS,"修改成功");
    public static final ResultCode FAIL_UPDATE = new ResultCode(Code.FAIL,"修改失败");

    public static final ResultCode SUCCESS_DELETE = new ResultCode(Code.SUCCESS,"删除成功");
    public static final ResultCode FAIL_DELETE = new ResultCode(Code.FAIL,"删除失败");

    public static final ResultCode FAIL_DEL = new ResultCode(Code.FAIL,"删除失败");

    private Integer code; // 状态码
    private String msg ; //响应消息

    public ResultCode(Integer code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }
}
